<?php echo $this->Html->script('Events/get_futbol_data_repositorie_dates');?>
<div class='span10'>
    <?php        
        if(count($data) <= 0)
        echo "No hay fechas en el torneo seleccionado"; 
        else
        {
        ?>
        <table class="table table-bordered">
                    <thead>
                                <tr>
                                        <th>Nombre</th>
                                        <th>Inicio</th>
                                        <th>Fin</th>
                                        <th>Estado</th>
                                        <th>Código</th>
                                </tr>
                    </thead>
                    <tbody>
                    <?php foreach($data as $field):?>	<a 			
                    <tr>
                        <td><?php echo '<a onClick="get_matchs_by_date(\''.$field['TournamentDates']['dateId'].'\')">'.$field['TournamentDates']['dateName'].'</a>';?></td>
                        <td><?php echo $field['TournamentDates']['dateStart']?></td>
                        <td><?php echo $field['TournamentDates']['dateEnd']?></td>
                        <td><?php echo $field['TournamentDates']['status']?></td>
                        <td><?php echo $field['TournamentDates']['dateId']?></td>
                    </tr>
                    <?php endforeach;?>
                    </tbody>
        </table>
        <?php
        }
        ?>
</div>